<template>
<uni-shadow-root class="partials-newsList-gongyi_news_list-index"><template name="gongyi_news_list_page">
<block>
<view class="i_news_list">
    <view class="i_news_list_icon">
        <image class="i_news_list_img" mode="aspectFit" :src="jsonData.newsIcon?jsonData.newsIcon:"https://image1.sansancloud.com/xianhua/2019_12/30/10/36/10_16.jpg?x-oss-process=style/preview_120""></image>
    </view> 
    <block v-if="relateBean.length >= "1"">
        <swiper :indicator-dots="false" class="i_news_swiper" display-multiple-items="2" autoplay="true" interval="5000" duration="500" vertical="true">
            <swiper-item v-for="(item,index) in (relateBean)" :key="item.index" class="i_news_item" v-if="index<jsonData.count" :data-item="item" @click="tolinkUrl">
                <view class="i_news_content">{{item.description}}</view>
            </swiper-item>
        </swiper>
    </block>
    <block v-if="relateBean.length==0">
        <view class="noproduct">
          <image mode="widthFix" src="https://image1.sansancloud.com/xianhua/2019_12/16/15/54/55_950.jpg?x-oss-process=style/preview_120"></image>
          <text>没有相关新闻</text>
        </view>
    </block>
</view>
</block>
</template></uni-shadow-root>
</template>

<script>

global['__wxRoute'] = 'partials/newsList/gongyi_news_list/index'

Component({})

export default global['__wxComponents']['partials/newsList/gongyi_news_list/index']
</script>
<style platform="mp-weixin">
.i_news_list{
    display: flex;
    flex-direction: row;
    align-items: center;
    height: 110rpx;
    background: #fff9ea;
}
.i_news_list_icon{
    width: 188rpx;
    height: 110rpx;
}
.i_news_list_img{
    width: 100%;
    height: 100%;
}
.i_news_swiper{
    display: flex; 
    flex-direction: column;
    padding: 18rpx 0;
    height: 110rpx;
    width: 520rpx;
    box-sizing: border-box;
}
.i_news_item{
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 100%;
    height: 34rpx;
    margin: 4rpx 0;
}
.i_news_content{
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    width: 100%;
    font-size: 24rpx;
}
</style>